// ScrollPane.h: interface for the ScrollPane class.
//
//////////////////////////////////////////////////////////////////////

#if !defined(AFX_SCROLLPANE_H__FEF855E1_BC26_11D2_B56A_006097A44215__INCLUDED_)
#define AFX_SCROLLPANE_H__FEF855E1_BC26_11D2_B56A_006097A44215__INCLUDED_

#if _MSC_VER >= 1000
#pragma once
#endif // _MSC_VER >= 1000

#include "Scroller.h"

class CLASS_DECL_D ScrollPaneViewport : public AWTPanel
{
DECLARE_DYNAMIC(ScrollPaneViewport)
public:
	ScrollPaneViewport(AWTContainer* c)
	{
		m_scroller = c;
	};
	virtual ~ScrollPaneViewport(){};

	virtual void doLayout();
	void eraseBackground(CDC* pDC){};

	void setOffset(CPoint off);

private:
	AWTContainer* m_scroller;
	CPoint m_offset;
};

class CLASS_DECL_D ScrollPane : public Scroller
{
DECLARE_DYNAMIC(ScrollPane)
public:
	ScrollPane();
	virtual ~ScrollPane();

	virtual void scrollTo(int x, int y);
	virtual CSize getScrollAreaSize();
	virtual void reshape(int x, int y, int w, int h);
	AWTComponent* add(AWTComponent* comp);
	void setOffset(CPoint pt)
		{m_offset = pt;}

protected:
	CPoint m_offset;
};

#endif // !defined(AFX_SCROLLPANE_H__FEF855E1_BC26_11D2_B56A_006097A44215__INCLUDED_)
